﻿using System.Linq;
using System.Collections.Generic;
using EPiServer.Core;
using OpenWaves.Collections;

namespace $rootnamespace$.Controls
{
    public class MegaMenuNode : NavigationNode
    {
        public MegaMenuNode(PageData page) : base(page) { }

        public IEnumerable<IEnumerable<NavigationNode>> Columns
        {
            get
            {
				//
				// This is where you can divide second level menu items into columns
				//
                return this.Children.GroupBy(2);
            }
        }
    }
}